import socket from "@/socket";

const actions = {
    sendMessage(context, data) {
        return new Promise((resolve, reject) => {
            socket.emit('send_message', data, res => resolve(res));
        })
    },
    delFriend(context, data) {
        return new Promise((resolve, reject) => {
            socket.emit('del_friend', data, res => resolve(res));
        })
    }
}

export default {
    namespaced: true,
    actions
}